<admintpl file="header" />
</head>
<body>
	<div class="wrap js-check-wrap">
		<ul class="nav nav-tabs">
			<li class="active"><a href="{:U('PromotionCoupon/index')}">优惠券列表</a></li>
			<li><a href="{:U('PromotionCoupon/add')}">添加优惠券</a></li>
		</ul>
		<form class="well form-search" method="post" action="{:U('PromotionCoupon/index')}">
			优惠券名称:
			<input type="text" name="coupon_name" style="width: 130px;" value="{:I('request.coupon_name/s','')}" placeholder="请输入优惠名称">

			<input type="submit" class="btn btn-primary" value="搜索" />
			<a class="btn btn-danger" href="{:U('PromotionCoupon/index')}">清空</a>
		</form>
		<table class="table table-hover table-bordered">
			<thead>
				<tr>
					<th>商户</th>
					<th>优惠名称</th>
					<th>兑换积分</th>
					<th>有效期</th>
					<th>数量</th>
					<th>已领取数量</th>
					<th>已使用数量</th>
					<th width="100">{:L('ACTIONS')}</th>
				</tr>
			</thead>
			<style>td{word-break:break-all;}</style>
			<tbody>
				<foreach name="list" item="vo">
				<tr>
					<td>{$vo.merchant_name}</td>
					<td>{$vo.coupon_name}</td>
					<td>{$vo.exintegral}</td>
					<td>{$vo.start_date}至{$vo.end_date}</td>
					<td>{$vo.total_num}</td>
					<td>{$vo.get_num}</td>
					<td>{$vo.use_num}</td>
					<td>
						<a href='{:U("PromotionCoupon/edit",array("id"=>$vo["id"]))}'>{:L('EDIT')}</a> |
						<a class="js-ajax-delete" href="{:U('PromotionCoupon/delete',array('id'=>$vo['id']))}">{:L('DELETE')}</a>
					</td>
				</tr>
				</foreach>
			</tbody>
		</table>
		<div class="pagination">{$page}</div>
	</div>
	<script src="__PUBLIC__/js/common.js"></script>
</body>
</html>